/*
Copyright (c) [2019年5月1日] [吴超]
[MBT_studio] is licensed under Mulan PSL v2.
You can use this software according to the terms and conditions of the Mulan PSL v2.
You may obtain a copy of Mulan PSL v2 at:
		 http://license.coscl.org.cn/MulanPSL2
THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
See the Mulan PSL v2 for more details.
*/
#pragma once

#include "节点/节点.h"
#include <粒子/粒子.h>
#include <物体/物体.h>




class C_粒子插座 : public C_插座基类 {
public:
	C_粒子插座(std::wstring name);
	~C_粒子插座();

	S_粒子插座数据*	m_Value;

	void*		f_getData(uint8 线程ID);
	void		f_setData(void* data, uint8 线程ID = 0);


	void	f_读取(FILE* f);
	void	f_写入(FILE* f);

	std::wstring		f_getTypeName() { return L"particle"; }
};
#define DEF_转换为粒子插座(socket) dynamic_cast<C_粒子插座*>( (socket) )
#define DEF_粒子插座Value(socket)  ((S_粒子插座数据*) ((socket)->f_getData(0)) )

#define DEF_创建粒子插座_I(name) socket = new C_粒子插座( (name) ); f_add插座(socket, E_插座方向::e_插座Type_输入);
#define DEF_创建粒子插座_O(name) socket = new C_粒子插座( (name) ); f_add插座(socket, E_插座方向::e_插座Type_输出);












